package com.atguigu.java.langchain4j.assitant;

import dev.langchain4j.service.MemoryId;
import dev.langchain4j.service.SystemMessage;
import dev.langchain4j.service.UserMessage;
import dev.langchain4j.service.V;
import dev.langchain4j.service.spring.AiService;

import static dev.langchain4j.service.spring.AiServiceWiringMode.EXPLICIT;

/**
 * @author 沈复龙
 * @date 2025/6/5
 * @description
 */
@AiService(
        wiringMode = EXPLICIT,
        chatModel = "qwenChatModel",
        chatMemoryProvider = "chatMemoryProvider",
       tools = "calculatorTools"
)
public interface SeparateAssistant {
    @SystemMessage("你是我的好朋友，请用东北话回答问题。今天是几号{{current_date}}")
    String chat(@MemoryId int memoryId, @UserMessage String message);


    @UserMessage("你是我的好朋友，请用粤语回答问题,{{message}}")
    String chat2(@MemoryId int memoryId, @V("message") String message);

    @SystemMessage(fromResource = "my-prompt-template3.txt")
    String chat3(
            @MemoryId int memoryId,
            @UserMessage String userMessage,
            @V("username") String username,
            @V("age") int age
    );
}
